package com.googlecode.lohr.parser.combinators.matcher;


import java.util.List;

import com.googlecode.lohr.parser.combinators.node.AbstractNode;
import com.googlecode.lohr.parser.combinators.node.Nodes;

public final class Matchers
{
	private Matchers()
	{
		throw new UnsupportedOperationException("Utility class");
	}

	public static String toStringFull(AbstractNode node)
	{
		return "Matched [" + node.length() + "] symbols, tree:\n" + Nodes.toStringFull(node) + "\n";
	}

	public static String toStringFull(List<AbstractNode> results)
	{
		StringBuilder builder = new StringBuilder();

		for (AbstractNode result : results)
			builder.append(toStringFull(result));
		
		return builder.toString();
	}
}
